package com.ruoyi.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 传感器（每个传感器也是一个 MQTT 设备）对象 tb_sensor
 * 
 * @author zhouxin
 * @date 2025-07-05
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class Sensor extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 传感器主键ID */
    private Long sensorId;

    /** 传感器名称 */
    @Excel(name = "传感器名称")
    private String mqttDeviceId;

    /** 传感器标识 */
    @Excel(name = "传感器标识")
    private String mqttSensorCode;

    /** 创建时间 */
    private Date createdAt;

    /** 更新时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "更新时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date updatedAt;

    //设备的名称
    private String  mqttName;

}
